package com.pomelo.springfile;

import com.jcraft.jsch.ChannelSftp;
import com.jcraft.jsch.JSchException;
import com.jcraft.jsch.SftpException;
import com.pomelo.springfile.common.FtpUtils;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

import java.util.Vector;

@SpringBootApplication
public class SpringFileApplication {

    public static void main(String[] args) throws JSchException, SftpException {
        SpringApplication.run(SpringFileApplication.class, args);
        long start = System.currentTimeMillis();
        Vector<ChannelSftp.LsEntry> allFile = FtpUtils.getAllFile();
        long end = System.currentTimeMillis();
        System.out.println("total time:" + ((end - start) / 1000) + "s");
    }

}
